package com.example.studentregistration.service;


import com.example.studentregistration.pojo.Users;
import com.example.studentregistration.util.Result;import com.github.pagehelper.Page;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;


//业务逻辑接口,处理业务逻辑

public interface UserService {
    //根据手机号查询用户
    Result< Users> queryUserByPhone(String phone);
    //添加 用户
    Result<?> insertUser(Users user);

    //修改用户
    Result<?> updateUser(Users user);

    //删除用户
    Result<?> deleteUser(Integer id);

    //查询所有用户
//    Result<?> queryAllUsers();
    Page queryAllUsers(Integer currentPage, Integer pageSize);

//    根据用户名查询用户
    Result<Users> queryUserByName(String username);

//    用户登录
    Result<?> login(String phone, String password);

    //文件导出操作
    void exportExcel(HttpServletResponse  response) throws IOException;
    //批量删除
    int batchDeleteUser(List<Integer> ids);


}
